import request from '@/utils/request'

export function financeQueryPage(data) { //财务统计
	return request({
		url: '/system/finance/queryPage',
		method: 'post',
		params: data
	})
}
export function getFinanceExcel(data) { //导出财务统计
	return request({
		url: '/system/finance/financeExcel',
		method: 'post',
		params: data,
		responseType: 'blob'
	})
}

export function getDangkouList(data) { //档口
	return request({
		url: '/system/consumption/dangkouList',
		method: 'post',
		params: data
	})
}

export function consumptionRecord(data) { //消费记录
	return request({
		url: '/system/consumption/consumptionRecord',
		method: 'post',
		params: data
	})
}

export function rechargeList(data) { //充值记录
	return request({
		url: '/system/consumption/rechargeList',
		method: 'post',
		params: data
	})
}

export function refundList(data) { //退款记录
	return request({
		url: '/system/consumption/refundList',
		method: 'post',
		params: data
	})
}

export function dangkouList(data) { //网点管理列表
	return request({
		url: '/system/dangkou/loadList',
		method: 'post',
		params: data
	})
}

export function dangkouSave(data) { //网点添加或编辑
	return request({
		url: '/system/dangkou/save',
		method: 'post',
		params: data
	})
}

export function dangkouDel(data) { //网点删除
	return request({
		url: '/system/dangkou/del',
		method: 'post',
		params: data
	})
}

export function groupList(data) { //商户列表
	return request({
		url: '/system/group/company/loadList',
		method: 'post',
		params: data
	})
}

export function groupSave(data) { //商户编辑和添加
	return request({
		url: '/system/group/company/save',
		method: 'post',
		params: data
	})
}

export function getGroupList(data) { //团餐公司list（档口添加使用）
	return request({
		url: '/system/dangkou/getGroupList',
		method: 'post',
		params: data
	})
}

export function subsidyUserList(data) { //补贴列表
	return request({
		url: '/system/subsidy/userList',
		method: 'post',
		params: data
	})
}

export function addSubsidy(data) { //补贴充值和扣除
	return request({
		url: '/system/subsidy/addSubsidy',
		method: 'post',
		params: data
	})
}

export function getSubsidyLog(data) { //补贴记录
	return request({
		url: '/system/subsidy/getSubsidyLog',
		method: 'post',
		params: data
	})
}

export function excelTemplate(data) { //补贴模板
	return request({
		url: '/system/subsidy/excelTemplate',
		method: 'post',
		params: data,
		responseType: 'blob'
	})
}

export function uploadSubsidy(data) { //导入补贴
	return request({
		url: '/system/subsidy/uploadSubsidy',
		method: 'post',
		data,
		upFile: true
	})
}

export function rechargExcel(data) { //充值记录导出
	return request({
		url: '/system/consumption/rechargExcel',
		method: 'post',
		params: data,
		responseType: 'blob'
	})
}

export function consumptionExcel(data) { //消费记录导出
	return request({
		url: '/system/consumption/consumptionExcel',
		method: 'post',
		params: data,
		responseType: 'blob'
	})
}

export function refundExcel(data) { //退款记录导出
	return request({
		url: '/system/consumption/refundExcel',
		method: 'post',
		params: data,
		responseType: 'blob'
	})
}

export function dangkous(data) { //档口下拉
	return request({
		url: '/system/consumption/dangkouList',
		method: 'post',
		params: data
	})
}

export function statistics(data) { //补贴金额统计
	return request({
		url: '/system/subsidy/statistics',
		method: 'post',
		params: data
	})
}

export function rechargeImport(data) { //充值导入
	return request({
		url: '/system/consumption/rechargeImport',
		method: 'post',
		data,
		upFile: true,
	})
}

export function conduct(data) { //一键补贴
	return request({
		url: '/system/subsidy/conduct',
		method: 'post',
		params: data
	})
}

export function detailsList(data) { //一键补贴
	return request({
		url: '/system/subsidy/detailsList',
		method: 'post',
		params: data
	})
}


